<?php

namespace app\controller;

use app\BaseController;
use app\message;
use app\model\SystemOperateLog;
use app\Request;
use app\stateData;

class SystemLog extends BaseController
{

    /**
     * 操作日志
     */

    //获取日志列表
    public function getLogList(Request $request,SystemOperateLog $log)
    {
        $page = $request->get ('page')?:1;
        $pageNum = $request->get ('pageNum')?:stateData::$_page;

        $where = $request->get('where');

        $result = $log->getLogModelList ($where,$pageNum,$page);

        $pages['total'] = $log->getWhereCount($where);

        $pages['pageNumber'] = $pageNum; //每页显示多少条

        return ReJson (message::$SUCC_CODE,message::$SUCC_SELECT_DATA,$result,$pages);
    }


}